'; window.popUpWin.document.write(zhtm); window.popUpWin.document.close(); // Johnny Jackson 4/28/98 } //--> Inside AutoCAD 14 -- Ch 21 -- Introduction to 3D


Inside AutoCAD 14

Previous chapterNext chapterContents


- 21 -

Introduction to 3D


by Don Spencer

Up to this point in this book, you have been drawing two-dimensional (2D) views of objects that, in their true form, are three-dimensional (3D). This method of designing and drafting is limited because the 2D representations must be interpreted to visualize the 3D object. In addition, 3D objects in a proper form can be used for the following purposes: viewing the model from any vantage point, creating 2D drafting views, visualizing shaded renderings (see fig. 21.1) and photo realistic renderings (images), reading data for FEA, creating animation, checking interference, and extracting manufacturing data. As you can see, using 3D objects can be quite valuable to your palette of AutoCAD. This chapter introduces you to the following topics:

Figure 21.1 A 3D surface model that has been shaded using the Shade command in AutoCAD.

Specifying 3D Coordinates

Understanding how to use the 3D coordinate systems is the key to creating 3D models in AutoCAD. Varied locations must be referenced on a 3D model or in 3D space to effectively use many of AutoCAD's 3D drawing, editing, viewing, and visualization tools.

The Right-Hand Rules

Two right-hand rules govern the 3D coordinate system. These are called "right-hand rules" because, quite simply, you actually use your right hand to determine the information you need to know. The first right-hand rule--Axis Direction--determines the positive axis direction of the Z axis when you know the positive direction of the X and Y axes. The second right-hand rule--Axis Rotation--determines the positive rotation direction about an axis. These rules are explained in the following sections.

Axis Direction

To determine the positive axis direction of the X, Y, and Z axes, place your right hand between yourself and the monitor. The back of your hand should be toward the screen. Point your thumb in the positive direction of the X axis. Next, point your index finger in the positive direction of the Y axis. Last, point your middle finger out of your palm, perpendicular to your thumb and index finger. This last movement indicates the positive direction of the Z axis.

Axis Rotation

To determine the positive rotation direction about an axis, point your right thumb in the positive direction of the axis and curl your fingers into a fist around the axis. Your fingers indicate the positive rotation direction about the axis.

3D Coordinate Input

Specifying 3D Cartesian coordinates (X,Y,Z) is similar to entering 2D coordinates (X,Y). You can enter absolute coordinate values--which are based on the origin--or relative coordinate values--which are based on the last point entered.

For both the World Coordinate System (WCS) and the user coordinate system (UCS), drawing in 3D requires X, Y, and Z values for the coordinate.

Cylindrical Coordinates

Cylindrical coordinate entry is similar to 2D polar coordinate entry, but this entry system includes an additional distance from the polar coordinate perpendicular to the XY plane. With cylindrical coordinate entry, you locate a point by specifying its distance along an angle relative to the UCS X axis and its Z value perpendicular to the XY plane.

For instance, the absolute coordinate 4<30,6 indicates a point four units from the origin of the current UCS, 30 degrees from the X axis in the XY plane, and six units along the Z axis. The relative cylindrical coordinate @2<60,3 indicates a point two units in the XY plane from the last point entered (not from the UCS origin point) at an angle of 60 degrees from the positive X direction. The line extends to a Z coordinate of three.

Spherical Coordinates

Spherical coordinate entry in 3D is also similar to polar coordinate entry in 2D. In this entry system, you locate a point by specifying its distance from the origin of the current UCS, its angle from the X axis (in the XY plane), and its angle from the XY plane. Each value is separated by an open angle bracket (<).

As an example, the coordinate 4<30<60 indicates a point four units from the origin of the current UCS in the XY plane, 30 degrees from the X axis in the XY plane, and 60 degrees up from the XY plane.

XYZ Point Filters

With XYZ point filters, you can extract coordinates from selected points and synthesize a new point using these coordinates. With this method, you can use known points to find an unknown point. On the Command: line use the following format:

Command: _line From point: .X

AutoCAD Release 14 accepts the following filter selections: .X, .Y, .Z, .XY, .XZ, and .YZ. For example, if you enter .X, you are prompted for the X coordinate and then the Y and Z values.

Defining a User Coordinate System in 3D Space

The User Coordinate System (UCS) provides the means to change the location of the 0,0,0 origin point, as well as the orientation of the XY plane and Z axis. Any plane or point in 3D space can be referenced, saved, and recalled, and you can define as many user coordinate systems as you require.

Usually, it is easier to align the coordinate system with existing geometry than to determine the exact placement of a 3D point. Coordinate input and display are relative to the current UCS, so if multiple viewports are active, they share the same UCS. AutoCAD Release 14 keeps track of the last 10 coordinate systems created in model space and the last 10 in paper space.

Specifying a New UCS

You can define a user coordinate system in one of the following ways:

In the following exercise, you will use UCS command options that you might not be using on 2D drawings to define user coordinate systems on 3D objects.

SPECIFYING A NEW UCS BY USING THE Z AXIS, 3-POINT, OBJECT, VIEW, AND PRESET OPTIONS

1. Open the 21CAD01.DWG drawing file on the accompanying CD-ROM.

2. Activate the left viewport by picking a point inside its boundaries.

3. Choose View>NAMED VIEWS to initiate the DDVIEW command. Then choose Int and then Restore, to restore the Int view (see fig. 21.2). You have effectively zoomed in to the lower-left corner of the 3D model so that you can better select point locations on the object.

Figure 21.2 The 21CAD01.DWG 3D wireframe drawing opened in AutoCAD.

4. Execute the UCS command from the Command: prompt by typing UCS and pressing Enter. Then choose the Z axis option.

5. Using the Intersection Object Snap, place the origin point <0,0,0> at the intersection of 1.

6. With the Midpoint Object Snap, choose the midpoint at 2 as a point on the positive portion of the Z axis.

7. Launch the UCS command just as you did in step 4 and enter World as the default to return to the World Coordinate System.

8. Run the UCS command again just as you did in step 4, and choose the 3-point option.

9. Using the Intersection Object Snap, place the origin point <0,0,0> at the intersection of 1.

10. Using the Midpoint Object Snap, choose the midpoint at 2 as a point on the positive portion of the X axis.

11. With the Midpoint Object Snap again, choose the midpoint at 3 as a point on the positive Y portion of the UCS XY plane. You have defined a new User Coordinate System by selecting three points to define a plane.


NOTE: You can define a UCS in 3D space using the 3-point option of the UCS command to specify the new UCS origin and the direction of its positive X and Y axes. The Z axis follows by applying the right-hand rule.

12. Enter the UCS command just as you did in step 4, and enter World as the default to return to the World Coordinate System.

13. Enter the UCS command just as you did in step 4, and choose the Object option.

14. Choose the 3D model at 4. The Object option aligns the new UCS with an existing object.

15. Enter the UCS command just as you did in step 4, and choose the View option.


NOTE:[ENND] The View option aligns the new UCS with the current viewing direction.

16. Restore the Top view by choosing View>NAMED VIEWS to initiate the DDVIEW command.

17. From the Tools pull-down menu, choose UCS, Preset UCS. This enters the DDUCSP command for you.

18. In the UCS Orientation dialog box, choose the Front icon. This is the center picture. Check on the Absolute to WCS dot. Then click on OK.


NOTE: Notice that the UCS icon changes to a box surrounding a broken pencil (see fig. 21.3) when you completed step 18. This new icon appears when the edge of the XY plane of the current UCS is almost perpendicular to your viewing direction or display screen.

Figure 21.3 The UCS icon changes to a broken pencil when the UCS becomes nearly perpendicular to the display screen.

19. Enter UCSFOLLOW at the command and set the value to 1 to turn UCSFOLLOW on. Repeat step 17, choosing other Preset UCS settings from the dialog box.


TIP: When UCSFOLLOW is turned on, a plan view is generated in the current viewport whenever you change from one UCS to another. UCSFOLLOW can be set separately for each viewport.

You now know how to successfully select a new UCS. The following section explains the use of the UCS icon, which you saw in this exercise.

The UCS Icon

The UCS icon is used to indicate the origin and orientation of the UCS in both 2D and 3D. The UCS icon also can be displayed at the UCS origin point. The same rules applying in 3D as in 2D, with the exception of the broken pencil (refer to fig. 21.3).

After you understand the 3D coordinate system, it is important to know how to create 3D objects in AutoCAD. The following section explains the three major types of 3D modeling and provides exercises on creating 3D objects.

Creating 3D Objects

AutoCAD Release 14 supports three basic types of 3D modeling:

Each type has its advantages and disadvantages, depending on the results desired. Each type also uses its own creation and editing techniques, which are explained in this section.


WARNING: It is not recommended that you mix modeling methods. Each modeling type uses a different method for constructing and editing 3D models, and only limited conversion between model types is available. For example, you cannot convert from wireframes to surfaces or from surfaces to solids.

Wireframe Modeling

A wireframe model is a skeletal description of a 3D object. No surfaces exist in a wireframe model because the model consists only of points, lines, and curves that describe the edges of the object. With AutoCAD 14, you can create wireframe models by positioning 2D (planar) objects anywhere in 3D space. Each object that makes up a wireframe model must be independently drawn and positioned.

In the following exercise, you will create a 3D wireframe by using lines, arcs, and circles. This requires changes to the UCS.

CREATE A 3D WIREFRAME MODEL BY USING LINES, ARCS, AND CIRCLES

1. Open the 21CAD02.DWG drawing file (see fig. 21.4).

Figure 21.4 The 21CAD02.DWG drawing contains two viewports.

2. Activate the left viewport by picking a point inside its boundaries.

3. Begin the Line command. Draw a line From point: 0,0 To point: 1.5,0 and press Enter to complete the command.

4. Begin the Arc command and press Enter at the <Start point>: prompt. Move the cursor around on the screen and see the following note. Next, at the End point: prompt enter @0,1.5 for the endpoint of the arc.


NOTE: Notice that the arc endpoint drag references the current UCS. Arcs, circles, and 2D polylines are drawn parallel to the current XY plane.

5. Begin the Line command, and press Enter past the From point: prompt. Set the length for the line at 1.5, and continue the line To point: 0,0.

6. Choose the Circle command. Using the Center Object Snap, pick the center of the arc as its center point. Enter a radius of .375 at the default Radius: prompt.

7. From the Copy command, select all the objects. Press Enter and give a Base point or displacement of 0,0. Press Enter and give a Second point of displacement of 0,0,1. Press Enter to complete the command.

8. Enter UCSFOLLOW at the Command: prompt to make sure UCSFOLLOW is set to 1.

9. From Named UCS, enter the DDUCS command, and make the Back UCS current (see fig. 21.5).

10. With the Zoom command, enter .5x to display the objects at one half of the current zoom factor. Next, pan the objects toward the bottom of the screen.

11. Begin the Line command and enter From point: 1.5,0 To point: 1.5,2. Press Enter to complete the command.

12. Begin the Arc command and press Enter at the <Start point>: prompt.

13 At the prompt End point: enter @-1.5,0 as the endpoint of the arc.

14. Begin the Line command, and press Enter at the From point: prompt. At the Length of line: prompt, set the line length at 2 to complete the outline of the back of the wireframe.

15. Choose the Circle command, using the Center Object Snap, and pick the center of the arc as its center point. Enter a radius of .375 at the default Radius: prompt.

Figure 21.5 The UCS in the 21CAD02.DWG drawing references the back plane.

16. From the Copy command, select the objects that you created in steps 11 through 15. Press Enter and give a Base point a displacement of 0,0. Press Enter and give a Second point of displacement a 0,0,.5. Press Enter to complete the command.

17. From the Standard toolbar, choose Preset UCS, set to Absolute to WCS, choose the Front icon, and then click on OK.

18. With the Zoom command, enter .5x to display the objects at one-half of the current zoom factor.

Figure 21.6 The finished 21CAD02.DWG drawing should appear similar to this after you have completed the clean up from step 19.

19. You can now Fillet or Trim, and add additional lines to match figure 21.6. The right viewport also can be used to draw lines, arcs, and circles to represent all the planar edges of the 3D model.

3D Wireframe Objects

AutoCAD also has 3D polylines and splines that can be used to create 3D wireframe objects. These can be drawn continuously over X,Y,Z coordinates.

Surface Modeling

Surface modeling is the most complex--and therefore the hardest to master--of the three modeling types in AutoCAD. AutoCAD's surfaces define not only the edges of a 3D object but also its surfaces.

Surface models are used when the level of detail about physical properties (such as mass, weight, and center of gravity) that solids provide are not needed but you still need the hiding, shading, and rendering capabilities that wireframes can't provide.

AutoCAD's surface modeler uses a polygonal mesh to define the faceted surfaces. The faces of the mesh are planar and can only approximate curved surfaces. Figure 21.7 illustrates how the curved surfaces of the surface model are represented with planar and faceted polygonal meshes.

Figure 21.7 A surface model with faceted surfaces and the boundaries used to define the surface.

The density of the surface mesh, or number of facets, is defined in terms of a matrix of M and N vertices. These are similar to a grid consisting of columns and rows. M specifies the column position, and N specifies the row position of any given vertex. Surface meshes can be created in both 2D and 3D.


NOTE: Faceted meshes are useful if you want to visualize a 3D model, especially geometry with unusual mesh patterns, such as a 3D topographical model. For true curved surfaces, you need an add-on AutoCAD product called AutoSurf. With AutoSurf, you can create true curved surfaces, and these surfaces can be used to manufacture the model.

Open and Closed Meshes

A mesh can be open or closed. A mesh is open in a given direction if the start and end edges of the mesh do not touch. AutoCAD provides several methods for creating both types of meshes.

Predefined 3D Surface Mesh

Some methods of creating surfaces in AutoCAD can be difficult to use when entering the mesh parameters manually. AutoCAD's 3D command is used to create basic surface shapes. The 3D command is accessed by entering 3D at the Command: prompt. You can also choose the basic surface shapes from the Surfaces toolbar and from the Draw pull-down menu under Surfaces, 3D Surfaces. The 3D command simplifies the process of creating the following 3D shapes: box, cone, dish, dome, mesh, pyramid, sphere, torus, and wedge (see fig. 21.8). These meshes are displayed as wireframes until you use the HIDE, SHADE, or RENDER commands.

Figure 21.8 Basic surface shapes are displayed as wireframes.


Additional Surfacing Commands

AutoCAD also provides the following surface creation commands: 3DFACE, 3DMESH, PFACE, EDGE, RULESURF, TABSURF, REVSURF, and EDGESURF. A thorough description of these commands is beyond the scope of this introductory chapter. For the following exercise, however, you should know that RULESURF is used to create a surface that is ruled or blended between two selected objects. EDGESURF uses a closed area defined by four edges to blend a surface over the closed area.

In the following exercise, you will use EDGESURF and RULESURF to create irregularly shaped surfaces. You also will control the density of the grid used to define the surfaces.

USING EDGESURF AND RULESURF TO CREATE IRREGULARLY SHAPED SURFACES

1. Open the 21CAD03.DWG drawing file.

2. From the Standard toolbar, choose NAMED VIEWS, to enter the DDVIEW command. Restore the Edge view.

3. Activate the Surfaces toolbar by choosing, View, Toolbars and checking Surfaces. click on OK.

4. From the Surfaces toolbar, choose the EDGESURF command and pick 1, 2, 3, and 4 (see fig. 21.9).

You now have defined the four edges of an open surface.

Figure 21.9 These objects are ready to have EDGESURF and RULESURF surfaces defined.

5. From the Erase command, enter an L to erase the last object drawn. This removes the surface mesh.

6. Enter SURFTAB1 at the Command: prompt, and change the value to 12.

7. Enter SURFTAB2 at the Command: prompt, and change the value to 18.

8. Repeat step 4 and refer to the following note.


NOTE: The SURFTAB setting variables are used to control the density of the M and N grid that defines the surface created.

9. Repeat step 2 to restore the Rule view.

10. From the Surfaces toolbar, choose the RULESURF command, and pick 5 and 6.


The surface now is ruled between the two entities selected. Notice that the SURFTAB1 setting is used for REVSURF (see fig. 21.10).


WARNING: Choosing 7 in step 10 usually produces an undesirable result for the Ruled surface. The surface will be crossed over or twisted. To get the desired results as in figure 21.10, the selection points on the objects should be toward the same end. You can verify this by erasing the last object created in step 10 and redoing step 10. This time, choose 7 instead of 6.

Figure 21.10 The completed edge and ruled surfaces created with EDGESURF and RULESURF.


Using Thickness to Simulate Meshes

Thickness is one method of simulating meshes in AutoCAD. The thickness of an object is the distance by which that object is extruded above or below its elevation (see fig. 21.11). Positive thickness extrudes upward (positive Z), and negative thickness extrudes downward (negative Z). A zero thickness means that the object has no extrusion value.

Thickness can be set with the THICKNESS or ELEV commands. The current thickness of objects being drawn remains in effect until the value is changed. AutoCAD applies the extrusion uniformly on an object.


NOTE: A single object cannot have a different thickness for its various points.

Several objects in AutoCAD ignore the current thickness and cannot be extruded. These include 3D faces, 3D polylines, 3D polygon meshes, dimensions, and viewports.

Text objects created with TEXT, DTEXT, and DDATTDEF or ATTDEF also ignore the current thickness. However, you can assign a nonzero thickness to these and other existing objects by using the DDMODIFY, DDCHPROP, CHPROP, or CHANGE commands.

Figure 21.11 After thickness is applied to the objects, the HIDE command is used to show that the object is not a solid.

Solid Modeling

Solid modeling with AutoCAD Release 14's ACIS solid modeler is easier and faster than wireframe and surface modeling in AutoCAD. Solid models provide the same display information as wireframe and surface models, and solids also represent the entire volume of an object. You can analyze solids for their mass properties (volume, moments of inertia, and center of gravity), and the data from a solid object can be exported to applications such as CNC or FEA.

The following four types of 3D solid models can be created in AutoCAD:

Primitive Solids

AutoCAD provides a basic set of solid objects called primitives that includes the following shapes: box, cone, cylinder, sphere, wedge, and torus (see fig. 21.12).

These shapes can be left as they are or can be combined with other solid types to create more complex solids called composite solids.

Figure 21.12 AutoCAD's primitive solids include these shapes.


Composite Solids

After you create any solid type, you can create more complex shapes by combining solids. You can join solids, subtract solids from each other, or find the common volume (overlapping portion) of solids with the following Boolean operation commands:

In the following exercise, you will create box and cylinder primitives and apply Boolean operations to these solids to create a composite solid.

CREATING A COMPOSITE SOLID USING BOX, CYLINDER, UNION, AND SUBTRACT

1. Open the 21CAD04.DWG drawing file.

2. Activate the left viewport by choosing a point within its boundaries.

3. Activate the Solids toolbar by choosing, View, Toolbars. Then check Solids from the Toolbars list box and click on OK.

4. Choose the BOX command from the Solids toolbar. Enter 0,0,0 at the Corner of box: prompt. Then enter 1.5,1.5,1 at the prompt for the other corner. You have defined the front lower-left and the back upper-right corners of a 3D solid box.

5. Using the CYLINDER command from the Solids toolbar. Create a cylinder with a center point at 1.5,.75, a radius of .75, and a height of 1.

6. Repeat step 3 to activate the Modify II toolbar.

7. With the UNION command from the Modify II toolbar, choose the box and the cylinder by picking on an edge of each object. Then press Enter to complete the command.


NOTE: With the UNION command, you can combine the total volume of two or more solids into a composite object (see fig. 21.13).

Figure 21.13 The box and cylinder are unioned into one composite solid.

8. From the Solids toolbar, choose Cylinder to create another cylinder with a center point of 1.5,.75 a radius of .375, and a height of 1.

9. Enter the SUBTRACT command from the Modify II toolbar and choose the composite solid created after step 7 by picking on one of its edges. This is the solid to subtract from. Press Enter, then type L. to select the cylinder created in step 8 as the solid to subtract. Now press Enter twice.


NOTE: The SUBTRACT command removes the common area of one set of solids from another. Remember that you first choose the solid that you want to keep, then the solid you want to subtract.


TIP: You can quickly verify that the .375 radius cylinder created in step 8, was subtracted from the composite model by activating the right viewport and entering the HIDE command (see fig. 21.14).

Figure 21.14 The cylinder is subtracted from the composite solid, and the right viewport is hidden to verify subtraction.

10. Activate the left viewport by choosing a point within its boundaries.

11. From the Standard toolbar, choose Named Views, and restore the Back view.

12. With the UCS command, use the View option to make the current UCS align with the view.

13. With the Zoom command, enter .5x to display the objects at one half of the current zoom factor. Next, pan toward the bottom of the view.

14. Enter the BOX command from the Solids toolbar. Enter 0,1,0 as the first corner and @1.5,1,.5 as the other corner. Notice where the box was drawn in the right viewport. It was drawn on top of the existing composite solid because the Y value for the first corner is 1.

15. From the Solids toolbar, choose the CYLINDER command. Enter a center point of .75,2, a radius of .75, and a height of .5.

16. From the Modify II toolbar, choose UNION. Union the box, cylinder, and composite solids into a single composite solid.

17. Create another cylinder by choosing the CYLINDER command from the Solids toolbar. Give a center point of .75,2, a radius of .375, and a height of .5.

18. From the Modify II toolbar, choose SUBTRACT and select the composite solid as the solid to subtract from. Press Enter and choose the cylinder created in step 17 as the solid to subtract from the composite solid.

You have now created a composite solid (see fig. 21.15) of the same model as the wireframe exercise, shown earlier in the chapter (refer to fig. 21.6).

Figure 21.15 The completed composite solid model appears with the hidden lines removed.


TIP: For the preceding exercise, the primitive solids should ideally be created before performing any Boolean operations. Then the two boxes and two .75 radius circles could be unioned in a single operation. The two .375 radius cylinders could then be subtracted from the composite solid, resulting in the same product, but with fewer operations.

Some solid models are more easily defined by finding their shared or common volume. In the following exercise, you will create a composite solid model from two extruded solids using the INTERSECT command.

CREATING A COMPOSITE SOLID WITH THE INTERSECT COMMAND

1. Open the 21CAD05.DWG drawing file (see fig. 21.16).

Figure 21.16 The 21CAD05.DWG drawing contains two extruded solids.

2. Enter the MOVE command, pick 1, and press Enter. Next, pick the intersection 2 as the base and 0,0 as the second point.

3. From the Modify II toolbar, choose the INTERSECT command, select both solid models, and press Enter (see fig. 21.17).

Figure 21.17 The completed composite solid model appears like this one.

With INTERSECT, you can create a composite solid from the common volume or shared area of two or more overlapping solids. INTERSECT removes the non-overlapping portions and creates a composite solid from the common volume (refer to fig. 21.17).


TIP: The INTERFERE command performs the same operation as INTERSECT, but it keeps the original two objects.

Extruded Solids

The EXTRUDE command is used to create solids by extruding (adding thickness to) selected objects. You can extrude closed objects, such as polylines, polygons, rectangles, circles, ellipses, closed splines, donuts, and regions.

In the following exercise, you will extrude a solid from a common profile of an object. Several steps can be eliminated over the use of primitives to create the same complex solid model.

EXTRUDING A SOLID FROM A COMMON PROFILE OF AN OBJECT USING THE EXTRUDE COMMAND

1. Open the 21CAD06.DWG drawing file.

2. Activate the left viewport by selecting a point within its boundaries.

3. Begin the PLINE command from 0,0 to 2.25,0 to 2.25,1 to .5,1 to .5,2.75 to 0,2.75 and close (see fig. 21.18).

Figure 21.18 This closed pline profile will be extruded.

4. Enter the EXTRUDE command from the Solids toolbar and choose the closed pline. Press Enter to continue, and give a Height of Extrusion of 1.5. Then press Enter through the defaults to finish the command (see fig. 21.19).

Figure 21.19 The extruded profile.


NOTE: You now have created a solid from the closed pline loop. This solid can be edited to produce the results seen in figure 21.20.

5. Enter the FILLET command and pick 1 (refer to fig. 21.19). At the Enter radius: prompt, give a radius of .75, and pick 2, 3, and 4. Then press Enter.


NOTE: This same FILLET command can be used with 2D objects. You will notice however, that you do not have to set a radius before selecting the first edge to be filleted. Additionally, you can select the actual edges to filleted, not the intersecting edges.

6. Complete the model as seen in figure 21.20 by placing the .375 radius solid cylinders concentric with the filleted radii. You can use a Center Object Snap to snap the cylinder's center point to the center of the filleted radii. Refer to the following note.

7. Then SUBTRACT the cylinders from the extruded and filleted complex solid.


NOTE: Remember that circles, arcs, and cylinders are drawn parallel to the XY plane. Cylinders then are given a height in the positive or negative Z direction. You must rotate the UCS to get the desired results.

Figure 21.20 The complete complex 3D solid model appears like this.


Tapered Extrusions

Tapering the extrusion is useful in specifying an angle along the sides of the extrusion. For example, you could apply this process to create a draft angle needed for a part mold.


WARNING: Avoid using extremely large tapered angles. If the angle is too large, the profile can taper to a point before it reaches the specified height. In some cases, AutoCAD will not complete the command.

Extruding Along a Path

You also can extrude an object along a path (see fig. 21.21). Lines, circles, arcs, ellipses, elliptical arcs, polylines, or splines can be paths. The path should not lie on the same plane as the profile, nor should it have areas of high curvature. If the path contains segments that are not tangent, AutoCAD extrudes the object along each segment and then miters the joint along the plane bisecting the angle formed by the segments.

Figure 21.21 A closed profile and path appear like this with completed extrusion.


WARNING: You cannot extrude 3D objects or objects contained within a block. Likewise, you cannot extrude polylines that have crossing or intersecting segments or that are not closed.


TIP: After the extrusion, AutoCAD deletes or retains the original 2D profile object, depending on the setting of the DELOBJ system variable. Usually you would want the original 2D object to be deleted. The DELOBJ setting should be 1 to delete objects. However, by retaining the profile, you can use it to make mating or slightly modified solid components.

Revolved Solids

REVOLVE is used to create a solid by revolving a closed object about the X or Y axis of the current UCS at a specified angle. Objects also can be revolved about a line, a polyline, or two specified points.

In the following exercise, you will create a revolved solid model from a section profile and subtract holes from the revolved solid model.

CREATING A REVOLVED SOLID MODEL AND SUBTRACTING CYLINDERS

1. Open the 21CAD07.DWG drawing file (see fig. 21.22).

Figure 21.22 A profile to revolve around an axis.

2. Activate the left viewport by selecting a point within its boundaries.

3. Enter the REVOLVE command from the Solids toolbar. Pick the closed polyline 1 and press Enter. Then choose the Object option and pick 2. Finally, enter full circle to complete the command.

4. From the pull-down menu, choose the View>3D Viewpoint>Plan View> Current UCS to bring the left viewport into PLAN view relative to the current UCS (see fig. 21.23).

5. With the Zoom command, enter .8x to display the objects at 80% of the current zoom factor.

Figure 21.23 The left viewport in PLAN view relative to the current UCS.

6. From the Solids toolbar, choose the Cylinder command to create a cylinder with a center point of 3,0, a radius of .75, and a height of 1.5.

7. Using the Array command, array the cylinder around the center of the revolved solid at 0,0 for a total of six cylinders.

8. From the Modify II toolbar, select the revolved solid as the solid from which to subtract. Press Enter and choose the cylinders created in step 7 as the solids to subtract from the revolved solid (see fig. 21.24).

Figure 21.24 The completed REVOLVED 3D solid model with cylinder holes removed.

The same rules for closed loops apply to the EXTRUDE and REVOLVE commands. You can use REVOLVE on closed objects, such as polylines, polygons, rectangles, circles, ellipses, and regions. Revolving donuts will give you a solid (not hollow) tube. You cannot revolve 3D objects, objects in blocks, and objects that intersect themselves.

Modifying Solids

As you saw in a previous exercise, solids can be further modified by filleting and chamfering their edges. Some commands on the Solids toolbar also enable you to slice a solid into two pieces or to obtain the 2D cross section of a solid.

Displaying Solids

The ISOLINES system variable controls the number of tessellation lines used to visualize curved portions of the wireframe (see fig. 21.25). The default value is 4, and valid integer values range from 0 to 2047.

Figure 21.25 The completed revolved 3D solid model contains ISOLINES set to 25.

The FACETRES system variable adjusts the smoothness of shaded and hidden-line objects (see fig. 21.26). The default value is 0.5, and valid values range from 0.01 to 10.0.


WARNING: Take care when changing the ISOLINES and FACETRES system variables. Each variable can greatly increase file size and region, hide, shade, and rendering times.

Figure 21.26 The hidden revolved 3D solid model with FACETRES set to 2.

Viewing in 3D

An AutoCAD drawing can be viewed from any 3D location in model space. Objects may be added, edited, and selected in any view. From a selected 3D viewpoint, hidden, shaded, and rendered objects can be better visualized to see height, width, and depth. Parallel projection or perspective view also can be defined.


WARNING: You cannot use the VPOINT, DVIEW, or PLAN commands to change the paper space view. The view in paper space always remains a plan view.


TIP: You can set up your paper space viewports with any standard and 3D model space view. This a good way of setting up orthographic, auxiliary, and isometric views into a single drawing using one 3D solid model (see fig. 21.27).

Figure 21.27 Multiple views in paper space produce these views of a single 3D solid.

Viewing Direction

Several commands enable you to set a viewing angle for an AutoCAD 3D model. You can set the viewing direction using the following commands:

In the following exercise, you will set up different views in model space viewports.

DEFINING DIFFERENT MODEL SPACE VIEWS USING DDVPOINT, VPOINT, PLAN, AND DVIEW

1. Open the 21CAD08.DWG drawing file.


NOTE: You are now looking at a 3D solid model in the WCS, plan, or top view.

2. Enter the DDVPOINT command by choosing View from the pull-down menu and then choosing 3D Viewpoint, Select. The DDVPOINT command activates the Viewpoint Presets dialog box (see fig. 21.28).

Figure 21.28 The Viewpoint Presets dialog box is activated by executing the DDVPOINT command.

3. Choose 1 and then 2.


NOTE: Notice that the value changes as the locations on the dialog box are selected. Viewing angles relative to the X axis and the XY plane are selected by clicking your pointing device inside the image tiles. These values also can be entered directly.

4. Click on to exit the Viewpoint Presets dialog box and to see the resulting view (see fig. 21.29).

Figure 21.29 The DDVPOINT command produces this 3D viewpoint.

5. Enter the PLAN command by choosing View from the pull-down menu and then choosing 3D Viewpoint, Plan View, and World UCS.


NOTE: Step 5 returns you to the plan view relative to the WCS, which is also the current UCS.

6. Enter the VPOINT command by choosing View from the pull-down menu and then choosing 3D Viewpoint, Rotate.


NOTE: Notice that there is a drag from the crosshair. This enables you to pick an angle from the screen.

7. Enter 135 and then -30 for the angle from the plane.


NOTE: You are now viewing the 3D model in the opposite direction the model was viewed in step 4. You can use the HIDE command to verify that the -30 is viewing the model from below (see fig. 21.30).

Figure 21.30 The 3D model viewed from below with hidden lines removed.

8. From the pull-down menu, choose the View, 3D Viewpoint, Plan View, World UCS to bring the drawing into PLAN view relative to the WCS.

9. Enter the DVIEW command by choosing View from the pull-down menu and then choosing 3D Dynamic View. Then choose the object and press Enter.

10. Enter the Camera option and slowly move the crosshair around the screen.


NOTE: Notice that the object is highlighted as you move around the screen. If you picked a point on-screen at this time, the object would be viewed at the location of the highlighted image.

11. At the Toggle angle in/Enter angle from XY plane prompt, give a value of 35.3 and then press Enter. Now give a value of -45 at the Toggle angle from/Enter angle in XY plane from X axis prompt, and press Enter again.

12. Continue in the DVIEW command. Choose the zoom option and set a zoom value of 50mm or as needed (see fig. 21.31).


NOTE: You have now defined a view that looks much like the one created in step 4. However, you are still using the DVIEW command to continue using its associated.

Figure 21.31 The 3D view created from the DVIEW command.

13. Continue in the DVIEW command and enter the Distance option from the DVIEW command. Set a new target distance of 12, and press Enter twice to exit the command.

14. Save this drawing under a new name called VISUAL.DWG. You will be using this view to do the following visualization exercises.

The Distance option in the DVIEW command puts the view into perspective mode. Notice the change in the UCS icon (see fig. 21.32).

Figure 21.32 The perspective view created from the DVIEW command.

Visualizing 3D Models

One of the main reasons to create 3D surface and solid models, is to better visualize them during the design process and as a completed model. Three commands enable this type of viewing of surfaces and solids:

These commands do involve some limits in their use. For example, you cannot edit hidden-line, shaded, or rendered views.

HIDE

Complex drawings often appear too cluttered to convey useful information. Other times, it might be hard to see the results of a command process on the object. Hiding the background portions of an objects that in reality would be obscured in the current view simplifies the display and clarifies the design.

In the following exercise, you will perform the HIDE command on the VISUAL.DWG drawing.

USING THE HIDE COMMAND TO BETTER VISUALIZE WHAT WOULD BE SEEN ON A TRUE 3D MODEL

1. Use the current drawing VISUAL.DWG, or open the 21CAD09.DWG file.

2. Enter the HIDE command so the view looks like the one shown in figure 21.33.

Figure 21.33 The VISUAL.DWG drawing with hidden lines removed.


TIP: Calculating and obscuring hidden lines can be time-consuming. You can zoom into a part of the drawing to exclude objects or portions of an object from the hide process. You also can hide selected objects in the drawing by using the DVIEW commands Hide option.

SHADE

Flat shading can produce a more realistic image of the model than hidden-line removal. In the shading process, AutoCAD performs a hide before creating a flat, shaded image of the drawing in the current viewport. AutoCAD provides a default light that comes from a single light source located directly behind you (an over-the-shoulder light). Two factors are used to compute the shade (brightness) of each surface:


TIP: The steeper the angle of the surface to your viewpoint, the darker the surface is shaded. The distance from your viewpoint has no effect on shading.

The higher the value of the SHADEDIF system variable, the greater the contrast in your image. The default for SHADEDIF is 70, but you can specify a value between 1 and 100.


In the following exercise, you will perform four different shading operations.

CREATING A SHADED IMAGE FROM A SOLID MODEL

1. Use the current drawing VISUAL.DWG, or open the 21CAD09.DWG drawing file.

2. From the View pull-down menu, choose Shade and then 256 Color.

3. From the View pull-down menu, choose Shade and then 256 Color Edge Highlight (see fig. 21.34).

Figure 21.34 The VISUAL.DWG drawing can be shaded using the 256 Color Edge Highlight option.

4. From the View pull-down menu, choose Shade and then 16 Color Hidden Line.

5. From the View pull-down menu, choose Shade and then 16 Color Filled.


TIP: The SHADEDGE system variable is used to control the different shading methods used in the preceding exercise. By setting this variable to your preferred shading method, you can obtain the desired shading when you enter the SHADE command at the Command: prompt.
Use smaller viewports to speed up the shading process. The smaller the area of screen, the faster the shading process.


NOTE: With the SHADE command, you cannot produce highlights, move the light, or add more lights.

RENDER

Rendering in AutoCAD adds depth and realism to the surface or solid model that a simple hidden-line or shaded image cannot. Rendering is accomplished by means of rendering algorithms, which are mathematical means of relating light, color, and shape. AutoCAD provides the following three types of rendering:

Rendered Image

The renderer in AutoCAD 14 is capable of creating photorealistic renderings with the proper material representations, lighting, shadow casting, and backgrounds applied. This capability was added from a Photo Realistic Rendering AutoCAD add-on product for Release 13 called AutoVision.

For your introduction to rendering, you can render your model without adding any lights, applying any materials, or setting up a scene. When you render a new model, the AutoCAD renderer automatically uses a virtual over-the-shoulder distant light much the same as shading uses. As with shading, you cannot move or adjust this light.

In the following exercise, you will use the RENDER command to create three types of renderings. You also will render a file, creating a raster image that can be opened in a paint program to be modified and printed.

CREATING RENDER IMAGES FROM A SOLID MODEL

1. Use the current drawing VISUAL.DWG, or open the 21CAD09.DWG drawing file.

2. From the View pull-down menu, choose Render, Render. This opens the Render dialog box (see fig. 21.35).

Figure 21.35 The Render dialog box.

3. Select Render Scene to render the current scene.

4. Re-enter the Render dialog box.

5. Select 1 to choose the Photo Real rendering type.

6. Select Render to render the current scene.

7. Re-enter the Render dialog box.

8. Select 1 to choose the Photo Raytrace rendering type.

9. Select Render to render the current scene.


Even though no materials and additional lights have been applied, you should notice a difference in the rendering time and the quality of the image. The Photo Raytrace option in the Render dialog box produces the highest-quality image of the three rendering type options. Therefore it takes more time to produce.

10. Re-enter the Render dialog box.

11. Pick 2 (refer to fig. 21.35), and then choose File to change the Rendering Destination.

12. Under the Destination portion of the Render dialog box, click on the More Options button to activate the File Output Configuration dialog box (see fig. 21.36).

Figure 21.36 The File Output Configuration dialog box.



NOTE: The default settings are for a BMP file type at 640*480 resolution and an 8-bit, 256-color depth. You can change the file type, resolution, and color depth in this dialog box.


WARNING: Higher resolution and/or greater color depth results in larger file sizes and longer rendering times.

13. Click on OK to close the File Output Configuration dialog box.

14. Select Render to render the current scene to a file.

15. Assign the name Visual to the render file in the Render File dialog box, and choose Save.


You now have a raster image file that can be viewed, edited, and printed from your favorite paint program that supports the file type chosen.


TIP: You can stop the rendering by pressing the Esc key to cancel the command.

The AutoCAD renderer is automatically loaded into memory when you first choose the RENDER command or a render option. To free memory, you can unload the renderer by entering RENDERUNLOAD at the command line.


Summary

In this chapter, you learned to how to define X,Y,Z coordinates in a 3D coordinate system. By defining a user coordinate system, you were able to create the three basic types of 3D modeling: wireframe models, surface models, and solid models.

Most exercises emphasized the solid model because this is the easiest and most useful of the three basic types of modeling. You also had the opportunity to try several approaches to modeling with solids.

In addition, you discovered that 3D views are necessary to visualize the design process leading to the project's completion. Without 3D views, it would be nearly impossible to ensure the integrity and accuracy of the 3D model.

Finally, this chapter explored 3D model visualization. By hiding, shading, and rendering your 3D solid or surface models, you were able to visualize your designs like never before.


Previous chapterNext chapterContents

© Copyright, Macmillan Computer Publishing. All rights reserved.